<!DOCTYPE html>
<!--suppress ALL-->
<html lang="en" xmlns:th="http://www.thymeleaf.org"
      xmlns:shiro="http://www.pollix.at/thymeleaf/shiro">
<head>
    <meta charset="UTF-8">
    <title>Title</title>
</head>
<link rel="stylesheet" th:href="@{/bootstrap/css/bootstrap.min.css}">
<link rel="stylesheet" th:href="@{/css/font-awesome.min.css}">
<link rel="stylesheet" th:href="@{/css/login.css}">
<body>
<form class="form-signin" id="frm" role="form" th:action="@{/user/login}" method="post">
    <h2 class="form-signin-heading"><i class="glyphicon glyphicon-user"></i> 用户登不录</h2>

    <span th:if="${!#strings.isEmpty(errorInfo)}" th:text="${errorInfo}"></span>
    <div class="form-group has-success has-feedback">
        <input type="text" class="form-control" name="username" id="username" placeholder="请输入登录账号" autofocus>
        <span class="glyphicon glyphicon-user form-control-feedback"></span>
    </div>
    <div class="form-group has-success has-feedback">
        <input type="text" class="form-control" name="password" id="password" placeholder="请输入登录密码" style="margin-top:10px;">
        <span class="glyphicon glyphicon-lock form-control-feedback"></span>
    </div>

    <button class="btn btn-lg btn-success btn-block" onclick="dologin()" > 登录</button>
</form>

<script th:src="@{/jquery/jquery-2.1.1.min.js}"></script>
<script th:src="@{/bootstrap/js/bootstrap.min.js}"></script>
<script>
        function dologin() {
            var username=$("#username").val();
            var password=$("#password").val();

            $("#frm").submit();
        }
</script>
</body>
</html>